package com.matt.foundation.push;

import lombok.Data;

import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;

/**
 * *******************************
 * Created by lch.
 * form com.matt
 * on 2018/12/18
 * *******************************
 */
@Data
public class PushMsgVo {

    //消息标题
    private String title;

    //消息内容
    private String content;

    //消息弹出对话框
    private String alert;

    //消息提示声音
    private String sound;

    //发送对象的别名
    private List<String> alias = new ArrayList<String>();

    //发送对象的regId
    private List <String> regIds = new ArrayList<String>();

    //发送对象的tag
    private List<String> tags = new ArrayList<>();

    //发送附带的消息
    private Map<String ,String> extras = new HashMap<String,String>();

    public static PushMsgVo of(String title,String content,String alert,String sound,List<String> alias,List<String> regIds,List<String> tags,Map<String ,String> extras){
        PushMsgVo vo = new PushMsgVo();
        vo.setTitle(title);
        vo.setContent(content);
        vo.setAlert(alert);
        vo.setSound(sound);
        vo.setAlias(alias);
        vo.setRegIds(regIds);
        vo.setExtras(extras);
        vo.setTags(tags);
        return vo;
    }
}
